import asyncio
import time

async def async_test(delay:int,content):
    await asyncio.sleep(delay)
    print(content)

async def main():
    try:
        await asyncio.wait_for( async_test(2, "killer"),timeout=1)
    except asyncio.TimeoutError:
        print("任务超时...")

if __name__ == '__main__':
    print(f"start at {time.strftime('%X')}")
    asyncio.run(main())
    print(f"end at {time.strftime('%X')}")